import type { Branch } from '@/types/branch'
import type { PageParams, PageResult } from '@/types/common'
import { http } from '@/utils/http'

/**
 * 分页门店列表
 */
export const pageSysBranch = (data?: PageParams) => {
  return http<PageResult<Branch>>({
    method: 'GET',
    url: '/api/branch/pageSysBranch',
    data,
  })
}

/**
 * 获取默认门店
 */
export const selectDefaultBranch = () => {
  return http<Branch>({
    method: 'GET',
    url: '/api/branch/selectDefaultBranch',
  })
}
